import request from '@/utils/request'

// 查询通知公告列表
export function listuserNotice(query) {
  return request({
    url: '/system/userNotice/list',
    method: 'get',
    params: query
  })
}

// 查询通知公告详细
export function getuserNotice(id) {
  return request({
    url: '/system/userNotice/' + id,
    method: 'get'
  })
}

// 新增通知公告
export function adduserNotice(data) {
  data.content=encodeURIComponent(data.content)
  return request({
    url: '/system/userNotice',
    method: 'post',
    data: data
  })
}

// 修改通知公告
export function updateuserNotice(data) {
  data.content=encodeURIComponent(data.content)
  return request({
    url: '/system/userNotice',
    method: 'put',
    data: data
  })
}

// 删除通知公告
export function deluserNotice(id) {
  return request({
    url: '/system/userNotice/' + id,
    method: 'delete'
  })
}

// 导出通知公告
export function exportuserNotice(query) {
  return request({
    url: '/system/userNotice/export',
    method: 'get',
    params: query
  })
}